package com.hjh.thymeleafdemo1.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

@Data
@TableName("dept")
public class Dept {
    @TableField("id")
    @TableId(type = IdType.AUTO)
    private int id;
    @TableField("dname")
    private String dname; // 部门名称

    public Dept(){}

    public Dept(int id, String dname) {
        this.id = id;
        this.dname = dname;
    }
}
